import {
    createSlice
} from "@reduxjs/toolkit";
import {useSelector} from "react-redux";

const authSlice = createSlice({
    name:"auth",
    initialState:{
        token:localStorage.getItem("token")
    },
    reducers:{

    }
})
export const useSelectorAuth = ()=>useSelector((state:any)=>state.auth);
export default authSlice.reducer;